<?php require 'gauche.tpl.php';?>
	<div id="content">
	    <div>
	        <h2>Statistiques</h2>
	        <table class="stats">
	           <tr>
	               <th id="f_nom">Nom <img id="filter" src="<?php echo $baseUri?>images/asc.png" /></th>
	               <th id="f_battle">Batailles</th>
	               <th id="f_wr">WinRate</th>
	               <th id="f_survie">Survie</th>
	               <th id="f_dgt">Dégâts moy.</th>
	               <th id="f_exp">Exp. moy.</th>
	               <th id="f_cap">Cap moy.</th>
	               <th id="f_def">Def Moy.</th>
	               <th id="f_kill">Kill moy.</th>
	               <th id="f_kdratio">Kill/Death</th>
	               <th id="f_tier">Tier moy.</th>
	               <th id="f_er">ER</th>
	               <th id="f_wn7">WN7</th>
	               <th id="f_wn8">WN8</th>
	               
               </tr>
	        <?php $i=0;
	            foreach ($membresStats as $membre => $stats) {
$i++;
                $class='';
                if ($i % 2 === 0) {
                    $class = 'class="paire"';
                }
	        ?>
	           <tr <?php echo $class?>>
	               <!-- <td><a href="<?php echo $baseUri?>Clan/StatMembres/<?php echo $stats['accountid'] ?>-<?php echo $membre?>"><?php echo $membre?></a></td> -->
	               <td><?php echo $membre?></td>
	               <td><?php echo number_format($stats['stats']['battles'], 0, ',',' ')?></td>
	               <td><?php echo number_format($stats['stats']['wins']/$stats['stats']['battles']*100, 2, ',', ' ')?> %</td>
	               <td><?php echo number_format($stats['stats']['survived_battles']/$stats['stats']['battles']*100, 2, ',',' ')?> %</td>
	               <td><?php echo number_format($stats['stats']['damage_dealt']/$stats['stats']['battles'], 2, ',',' ')?></td>
	               <td><?php echo number_format($stats['stats']['xp']/$stats['stats']['battles'], 2, ',',' ')?></td>
	               <td><?php echo number_format($stats['stats']['capture_points']/$stats['stats']['battles'], 2,',',' ')?></td>
	               <td><?php echo number_format($stats['stats']['dropped_capture_points']/$stats['stats']['battles'], 2,',',' ')?></td>
	               <td><?php echo number_format($stats['stats']['frags']/$stats['stats']['battles'], 2,',',' ')?></td>
	               <td><?php echo number_format($stats['stats']['frags']/($stats['stats']['battles']-$stats['stats']['survived_battles']), 2, ',',' ')?></td>
	               <td><?php echo $stats['stats']['tiers']?></td>
	               <td class="<?php echo $stats['ER_status']?>"><?php echo $stats['ER']?></td>
	               <td class="<?php echo $stats['WN7_status']?>"><?php echo $stats['WN7']?></td>
	               <td class="<?php echo $stats['WN8_status']?>"><?php echo $stats['WN8']?></td>
               </tr>
	        <?php }?>
	        </table>
		</div>
		
	</div>